package com.cn.xiaonuo.tcrfinance.tcrshops.mapper;


import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.cn.xiaonuo.tcrfinance.tcrshops.entity.HpcProductResult;
import com.cn.xiaonuo.tcrfinance.tcrshops.entity.PvProduct;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;
import java.util.Map;

@Repository
@Mapper
public interface PvProductMapper extends BaseMapper<PvProduct> {
    //查询用户当天释放某个商品的总数量
    Integer clearVolume();

    /**
     * 商品名字
     *
     * @return
     */
    List<HpcProductResult> queryProductNameList(HpcProductResult productResult);

    /**
     * 查看商品类别
     */
    List<Map<String, Object>> queryProductNumByUserId(@Param("productId") Integer productId,
                                                      @Param("productName") String productName,
                                                      @Param("accounts") String accounts,
                                                      @Param("phone") String phone
    );

    List<Map<String, Object>> queryHtProductList(@Param("pickProductIdList") List<String> pickProductIdList);

    List<Map<String, Object>> queryEntrustListCount(@Param("delegateMode") String delegateMode,
                                                    @Param("pickProductIdList") List<String> pickProductIdList);

    /**
     * 查询最大商品排序
     *
     * @return java.lang.Integer
     */
    Integer selectMaxOSort();
}
